{% extends "base.html" %}  
{% block title %} 患者列表 {% endblock %}  

{% block content %} 

  <div class="container">

    <!-- Docs nav
    ================================================== -->
    <div class="row">
      <div class="span3 bs-docs-sidebar">
        <ul class="nav nav-list bs-docs-sidenav">    
        <li><a href="{% url sle.views.list_follow id %}"><i class="icon-chevron-right"></i> 返回列表</a></li>     
          <li><a href="#SSDDI"><i class="icon-chevron-right"></i> SSDDI</a></li>
          <li><a href="#SSDI"><i class="icon-chevron-right"></i> SSDI</a></li>
          <li><a href="#ESSDAI"><i class="icon-chevron-right"></i> ESSDAI</a></li>
          <li><a href="#ESSPRI"><i class="icon-chevron-right"></i> ESSPRI </a></li>
          <li><a href="#PCS"><i class="icon-chevron-right"></i> sf-12/PCS</a></li>
          <li><a href="#MCS"><i class="icon-chevron-right"></i> sf-12/MCS</a></li>
                
        </ul>
      </div>
      
      

<div class="span9">
              
          <section id="SSDDI">
          <div class="page-header">
            <h2>SSDDI 图表</h2>
          </div>

        
<div class="bs-docs-example">

<div align="center">
 <div class="row-fluid show-grid">
   <div class="span12">
  <input name="ssddi_bdate" id="ssddi_bdate" type="text" class="input-small" placeholder="开始日期" onFocus="HS_setDate(this)"  style="margin-top:8px;"/>
&nbsp;&nbsp;----&nbsp;&nbsp;
  <input name="ssddi_edate" id="ssddi_edate" type="text" class="input-small" placeholder="结束日期" onFocus="HS_setDate(this)"  style="margin-top:8px;"/>
  &nbsp;&nbsp;&nbsp;&nbsp;<input type="button" id="ssddi_submit" value="查看图表" name="B2" class="btn btn-info" /> 
  </div>
 </div>
  <div id="SSDDI_chart" style="margin-top:2px; margin-left:20px; width:640px; height:460px;"></div>           
</div>
</div>
</section>  



<section id="SSDI">
          <div class="page-header">
            <h2>SSDI 图表</h2>
          </div>
<div class="bs-docs-example">
<div align="center">
 <div class="row-fluid show-grid">
   <div class="span12">
  <input name="ssdi_bdate" id="ssdi_bdate" type="text" class="input-small" placeholder="开始日期" onFocus="HS_setDate(this)"  style="margin-top:8px;"/>
&nbsp;&nbsp;----&nbsp;&nbsp;
  <input name="ssdi_edate" id="ssdi_edate" type="text" class="input-small" placeholder="结束日期" onFocus="HS_setDate(this)"  style="margin-top:8px;"/>
  &nbsp;&nbsp;&nbsp;&nbsp;<input type="button" id="ssdi_submit" value="查看图表" name="B2" class="btn btn-info" /> 
  </div>
 </div>
  <div id="SSDI_chart" style="margin-top:2px; margin-left:20px; width:640px; height:460px;"></div>      
</div>
</div>
</section>


<section id="ESSDAI">
          <div class="page-header">
            <h2>ESSDAI 图表</h2>
          </div>
<div class="bs-docs-example">
<div align="center">
 <div class="row-fluid show-grid">
   <div class="span12">
  <input name="essdai_bdate" id="essdai_bdate" type="text" class="input-small" placeholder="开始日期" onFocus="HS_setDate(this)"   style="margin-top:8px;"/>
&nbsp;&nbsp;----&nbsp;&nbsp;
  <input name="essdai_edate" id="essdai_edate" type="text" class="input-small" placeholder="结束日期" onFocus="HS_setDate(this)"  style="margin-top:8px;"/>
  &nbsp;&nbsp;&nbsp;&nbsp;<input type="button" id="essdai_submit" value="查看图表" name="B2" class="btn btn-info" /> 
  </div>
 </div>
  <div id="ESSDAI_chart" style="margin-top:2px; margin-left:20px; width:640px; height:460px;"></div>      
</div>
</div>
</section>


<section id="ESSPRI">
          <div class="page-header">
            <h2>ESSPRI 图表</h2>
          </div>
<div class="bs-docs-example">
<div align="center">
 <div class="row-fluid show-grid">
   <div class="span12">
  <input name="esspri_bdate" id="esspri_bdate" type="text" class="input-small" placeholder="开始日期" onFocus="HS_setDate(this)"   style="margin-top:8px;"/>
&nbsp;&nbsp;----&nbsp;&nbsp;
  <input name="esspri_edate" id="esspri_edate" type="text" class="input-small" placeholder="结束日期" onFocus="HS_setDate(this)"  style="margin-top:8px;"/>
  &nbsp;&nbsp;&nbsp;&nbsp;<input type="button" id="esspri_submit" value="查看图表" name="B2" class="btn btn-info" /> 
  </div>
 </div>
  <div id="ESSPRI_chart" style="margin-top:2px; margin-left:20px; width:640px; height:460px;"></div>      
</div>
</div>
</section>



<section id="PCS">
          <div class="page-header">
            <h2>sf12-PCS 图表</h2>
          </div>
<div class="bs-docs-example">
<div align="center">
 <div class="row-fluid show-grid">
   <div class="span12">
  <input name="pcs_bdate" id="pcs_bdate" type="text" class="input-small" placeholder="开始日期" onFocus="HS_setDate(this)"   style="margin-top:8px;"/>
&nbsp;&nbsp;----&nbsp;&nbsp;
  <input name="pcs_edate" id="pcs_edate" type="text" class="input-small" placeholder="结束日期" onFocus="HS_setDate(this)"  style="margin-top:8px;"/>
  &nbsp;&nbsp;&nbsp;&nbsp;<input type="button" id="pcs_submit" value="查看图表" name="B2" class="btn btn-info" /> 
  </div>
 </div>
  <div id="PCS_chart" style="margin-top:2px; margin-left:20px; width:640px; height:460px;"></div>      
</div>
</div>
</section>



<section id="MCS">
          <div class="page-header">
            <h2>sf12-MCS 图表</h2>
          </div>
<div class="bs-docs-example">
<div align="center">
 <div class="row-fluid show-grid">
   <div class="span12">
  <input name="mcs_bdate" id="mcs_bdate" type="text" class="input-small" placeholder="开始日期" onFocus="HS_setDate(this)"   style="margin-top:8px;"/>
&nbsp;&nbsp;----&nbsp;&nbsp;
  <input name="mcs_edate" id="mcs_edate" type="text" class="input-small" placeholder="结束日期" onFocus="HS_setDate(this)"  style="margin-top:8px;"/>
  &nbsp;&nbsp;&nbsp;&nbsp;<input type="button" id="mcs_submit" value="查看图表" name="B2" class="btn btn-info" /> 
  </div>
 </div>
  <div id="MCS_chart" style="margin-top:2px; margin-left:20px; width:720px; height:500px;"></div>      
</div>
</div>
</section>






</div>

</div>
</div>


{% endblock %} 

{% block some_js %}



<script class="code" type="text/javascript">

  
  
  
  //ssddi开始
  $('#ssddi_submit').click(function(){

  if( Date.parse($('#ssddi_bdate').val()) <= Date.parse($('#ssddi_edate').val()) ){

  $.get("{% url sle.views.ssddi_chart %}",{
  bdate:$('#ssddi_bdate').val(),
  edate:$('#ssddi_edate').val(),
  patient_id:'{{id}}',
  
  } , function (data){
  
   $('#SSDDI_chart').empty();
  var plot1 = $.jqplot('SSDDI_chart', [data], {
	  title: {
        text: 'SSDDI 图表分析',  //设置当前图的标题
        show: true,//设置当前图的标题是否显示
		fontSize:18,
    },
      axes:{
        xaxis:{
          renderer:$.jqplot.DateAxisRenderer,
          tickRenderer: $.jqplot.CanvasAxisTickRenderer,
                numberTicks: 7,
				fontFamily:'Tahoma',
                tickOptions: {
                    angle: -30,
					formatString: '%Y-%m-%d', 
					tickInterval:'2 weeks',
                }
        },
        yaxis:{
		tickRenderer: $.jqplot.CanvasAxisTickRenderer,
          tickOptions:{
		    angle: -10,
            formatString:'%.1f——'
            }
        }
      },
      highlighter: {
        show: true,
        sizeAdjust: 7.5,

      },
      cursor: {
        show: false
      }
  });

  },'json');

  }else{

  alert("起始日期 不能 晚于 结束日期!");  

  }
  
  });//ssddi_submit 结束
  
  
  
 //ssdi开始
  $('#ssdi_submit').click(function(){

  if( Date.parse($('#ssdi_bdate').val()) <= Date.parse($('#ssdi_edate').val()) ){

  $.get("{% url sle.views.ssdi_chart %}",{
  bdate:$('#ssdi_bdate').val(),
  edate:$('#ssdi_edate').val(),
  patient_id:'{{id}}',
  
  } , function (data){
  
   $('#SSDI_chart').empty();
  var plot1 = $.jqplot('SSDI_chart', [data], {
	  title: {
        text: 'SSDI 图表分析',  //设置当前图的标题
        show: true,//设置当前图的标题是否显示
		fontSize:18,
    },
      axes:{
        xaxis:{
          renderer:$.jqplot.DateAxisRenderer,
          tickRenderer: $.jqplot.CanvasAxisTickRenderer,
                numberTicks: 7,
				fontFamily:'Tahoma',
                tickOptions: {
                    angle: -30,
					formatString: '%Y-%m-%d', 
					tickInterval:'2 weeks',
                }
        },
        yaxis:{
		tickRenderer: $.jqplot.CanvasAxisTickRenderer,
          tickOptions:{
		    angle: -10,
            formatString:'%.1f——'
            }
        }
      },
      highlighter: {
        show: true,
        sizeAdjust: 7.5,

      },
      cursor: {
        show: false
      }
  });

  },'json');

  }else{

  alert("起始日期 不能 晚于 结束日期!");  

  }
  
  });//ssdi_submit 结束


//essdai开始
  $('#essdai_submit').click(function(){

  if( Date.parse($('#essdai_bdate').val()) <= Date.parse($('#essdai_edate').val()) ){

  $.get("{% url sle.views.essdai_chart %}",{
  bdate:$('#essdai_bdate').val(),
  edate:$('#essdai_edate').val(),
  patient_id:'{{id}}',
  
  } , function (data){
  
   $('#ESSDAI_chart').empty();
  var plot1 = $.jqplot('ESSDAI_chart', [data], {
	  title: {
        text: 'ESSDAI 图表分析',  //设置当前图的标题
        show: true,//设置当前图的标题是否显示
		fontSize:18,
    },
      axes:{
        xaxis:{
          renderer:$.jqplot.DateAxisRenderer,
          tickRenderer: $.jqplot.CanvasAxisTickRenderer,
                numberTicks: 7,
				fontFamily:'Tahoma',
                tickOptions: {
                    angle: -30,
					formatString: '%Y-%m-%d', 
					tickInterval:'2 weeks',
                }
        },
        yaxis:{
		tickRenderer: $.jqplot.CanvasAxisTickRenderer,
          tickOptions:{
		    angle: -10,
            formatString:'%.1f——'
            }
        }
      },
      highlighter: {
        show: true,
        sizeAdjust: 7.5,

      },
      cursor: {
        show: false
      }
  });

  },'json');

  }else{

  alert("起始日期 不能 晚于 结束日期!");  

  }
  
  });//essdai_submit 结束
  
  
  
  

  //esspri开始
  $('#esspri_submit').click(function(){

  if( Date.parse($('#esspri_bdate').val()) <= Date.parse($('#esspri_edate').val()) ){

  $.get("{% url sle.views.esspri_chart %}",{
  bdate:$('#esspri_bdate').val(),
  edate:$('#esspri_edate').val(),
  patient_id:'{{id}}',
  
  } , function (data){
  
   $('#ESSPRI_chart').empty();
  var plot1 = $.jqplot('ESSPRI_chart', [data], {
	  title: {
        text: 'ESSPRI 图表分析',  //设置当前图的标题
        show: true,//设置当前图的标题是否显示
		fontSize:18,
    },
      axes:{
        xaxis:{
          renderer:$.jqplot.DateAxisRenderer,
          tickRenderer: $.jqplot.CanvasAxisTickRenderer,
                numberTicks: 7,
				fontFamily:'Tahoma',
                tickOptions: {
                    angle: -30,
					formatString: '%Y-%m-%d', 
					tickInterval:'2 weeks',
                }
        },
        yaxis:{
		tickRenderer: $.jqplot.CanvasAxisTickRenderer,
          tickOptions:{
		    angle: -10,
            formatString:'%.1f——'
            }
        }
      },
      highlighter: {
        show: true,
        sizeAdjust: 7.5,

      },
      cursor: {
        show: false
      }
  });

  },'json');

  }else{

  alert("起始日期 不能 晚于 结束日期!");  

  }
  
  });//esspri_submit 结束
  
  
         //pcs开始
  $('#pcs_submit').click(function(){

  if( Date.parse($('#pcs_bdate').val()) <= Date.parse($('#pcs_edate').val()) ){

  $.get("{% url sle.views.pcs_chart %}",{
  bdate:$('#pcs_bdate').val(),
  edate:$('#pcs_edate').val(),
  patient_id:'{{id}}',
  
  } , function (data){
  
   $('#PCS_chart').empty();
  var plot1 = $.jqplot('PCS_chart', [data], {
	  title: {
        text: 'sf12-PCS 图表分析',  //设置当前图的标题
        show: true,//设置当前图的标题是否显示
		fontSize:18,
    },
      axes:{
        xaxis:{
          renderer:$.jqplot.DateAxisRenderer,
          tickRenderer: $.jqplot.CanvasAxisTickRenderer,
                numberTicks: 7,
				fontFamily:'Tahoma',
                tickOptions: {
                    angle: -30,
					formatString: '%Y-%m-%d', 
					tickInterval:'2 weeks',
                }
        },
        yaxis:{
		tickRenderer: $.jqplot.CanvasAxisTickRenderer,
          tickOptions:{
		    angle: -10,
            formatString:'%.1f——'
            }
        }
      },
      highlighter: {
        show: true,
        sizeAdjust: 7.5,

      },
      cursor: {
        show: false
      }
  });

  },'json');

  }else{

  alert("起始日期 不能 晚于 结束日期!");  

  }
  
  });//pcs_submit 结束
  
  
  
        //mcs开始
  $('#mcs_submit').click(function(){

  if( Date.parse($('#mcs_bdate').val()) <= Date.parse($('#mcs_edate').val()) ){

  $.get("{% url sle.views.mcs_chart %}",{
  bdate:$('#mcs_bdate').val(),
  edate:$('#mcs_edate').val(),
  patient_id:'{{id}}',
  
  } , function (data){
  
   $('#MCS_chart').empty();
  var plot1 = $.jqplot('MCS_chart', [data], {
  
  
	  title: {
        text: 'sf12-MCS 图表分析',  //设置当前图的标题
        show: true,//设置当前图的标题是否显示
		fontSize:18,
    },
      axes:{
        xaxis:{
          renderer:$.jqplot.DateAxisRenderer,
          tickRenderer: $.jqplot.CanvasAxisTickRenderer,
                numberTicks: 7,
				fontFamily:'Tahoma',
                tickOptions: {
                    angle: -30,
					formatString: '%Y-%m-%d', 
					tickInterval:'2 weeks',
                }
        },
        yaxis:{
		tickRenderer: $.jqplot.CanvasAxisTickRenderer,
          tickOptions:{
		    angle: -10,
            formatString:'%.1f——'
            }
        }
      },
	  
      highlighter: {
        show: true,
        sizeAdjust: 7.5,

      },
      cursor: {
        show: false
      }
  });
  
  

  
  

  },'json');

  }else{

  alert("起始日期 不能 晚于 结束日期!");  

  }
  
  });//mcs_submit 结束
  
  
  

</script>



{% endblock %}